//加载模块
var http = request('http');
//创建服务
var server = http.createSevre()
//监听request事件
server.on('request', (req, res) => {
    console.log('由用户进来了')
    res.setHeader("Content-type","test/plain;charset=utf-8")
    res.end('hello，你好')
})
server.listen(3000,() => {
    console.log('服务器启动成功，访问：https://localhost:3000');
})